//
//  GameScene.h
//  CandyDizzle
//
//  Created by Cloner Team on 8/2/14.
//
//

#ifndef GAME_SCENE_H
#define GAME_SCENE_H

#include <iostream>
#include "AbstractScene.h"

#include "../layers/GUILayer.h"

class GameScene: public AbstractScene {
protected:
    GUILayer* guiLayer;
    UGLayer* backgroundLayer;
    UGLayer* gameLayer;
    GameListener* gameListener;
public:
    GameScene();
    ~GameScene();
    CREATE_FUNC(GameScene);
private:
    void createLayers();
    void createLayersContent();
    void initialize();
    
    virtual void update(float dt);
    virtual void onEnter();
    virtual void onExit();
    
    void onFireNewColor(Ref* data);
    void onFireIncreaseSpeed(Ref* data);
    void onFireCorrectChoice(Ref* data);
    void onFireReturnToNormal(Ref* data);
    
};

class IncreaseSpeed: public Speed {
public:
    typedef Speed super;
    static float multiply;
    static IncreaseSpeed* create(ActionInterval* action, float speed);
    virtual void step(float dt) override;
};

#endif /* defined(__CandyDizzle__GameScene__) */
